/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package br.ufba.lasid.v1.jitclouds.mda.datatypes.enums;

import static br.ufba.lasid.v1.jitclouds.mda.datatypes.enums.ContextKind.*;

/**
 *
 * @author aliriosa
 */
public enum ProcedureKind{

    /**
     * Cloud Procedure Kinds
     */
    CloudDeploymentProcedure             (CloudContext),
    CloudReplicationProcedure            (CloudContext),
    CloudRecoveryProcedure               (CloudContext),
    CloudFaultNotificationProcedure      (CloudContext),
    CloudSynchronizationProcedure        (CloudContext),

    /**
     * Data Center Procedure Kinds
     */
    DCDeploymentProcedure                (DCContext),
    DCReplicationProcedure               (DCContext),
    DCRecoveryProcedure                  (DCContext),
    DCFaultNotificationProcedure         (DCContext),
    DCSynchronizationProcedure           (DCContext),                        
    DCFailoverDeploymentProcedure        (DCContext),                        

    /**
     * Cluster Procedure Kinds
     */
    ClusterDeploymentProcedure           (ClusterContext),
    ClusterReplicationProcedure          (ClusterContext),
    ClusterRecoveryProcedure             (ClusterContext),
    ClusterFaultNotificationProcedure    (ClusterContext),
    ClusterSynchronizationProcedure      (ClusterContext),                        

    /**
     * Node Procedure Kinds
     */
    NodeDeploymentProcedure              (NodeContext),
    NodeReplicationProcedure             (NodeContext),
    NodeRecoveryProcedure                (NodeContext),
    NodeFaultNotificationProcedure       (NodeContext),
    NodeSynchronizationProcedure         (NodeContext),                                    

    /**
     * Hypervisor Procedure Kinds
     */
    HypervisorDeploymentProcedure        (HypervisorContext),
    HypervisorReplicationProcedure       (HypervisorContext),
    HypervisorRecoveryProcedure          (HypervisorContext),
    HypervisorFaultNotificationProcedure (HypervisorContext),
    HypervisorSynchronizationProcedure   (HypervisorContext),                                    

    /**
     * VM Procedure Kinds
     */
    VMDeploymentProcedure               (VMContext),
    VMReplicationProcedure              (VMContext),
    VMRecoveryProcedure                 (VMContext),
    VMFaultNotificationProcedure        (VMContext),
    VMSynchronizationProcedure          (VMContext),
    VMFailoverDeploymentProcedure       (VMContext),                        

    /**
     * General Procedure Kinds
     */
    DeploymentProcedure                  (UnknownContext),        
    ReplicationProcedure                 (UnknownContext),
    RecoveryProcedure                    (UnknownContext),
    NotificationProcedure                (UnknownContext),
    SynchronizationProcedure             (UnknownContext);

    private final ContextKind context;

    ProcedureKind(ContextKind context){
        this.context = context;
    }

    @Override
    public String toString() {
        if(context != null){
            return context.toString() + "." + super.toString();
        }

        return super.toString();

    }

    public ContextKind getContext(){
        return context;
    }

}    
